<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html >
<html>


<head>
<jsp:include page="/jsp/header.jsp" />
<title>Issued Books</title>
<link rel="stylesheet" href="../css/stylesheet.css" type="text/css"></link>



<script type="text/javascript">
    function validateForm() {

        var x = document.forms["DateChooser2"]["issuedate"].value;
        var y = new Date();
        var z = DateChooser2.DateChooser.min;
     

        if (new Date(x) > new Date(y)) {
            alert("Enter a valid Date (Date on or before today)");
            return false;
        }

        if (new Date(z) > new Date(x)) {
        	
            alert("Enter a valid Date (Date on or after 01/01/2000)");
            return false;
        }

    }
  </script>
</head>
<body>
<div id="IssuedBooks">
<table class="tab">
	<tr>
		<td> <img class="img" src="../../images/Sketchbook-64.png" alt="book" width="72" height="72" /> </td>
		<td class="label">Issued Books On:</td>
		<td> <form name="DateChooser2" action="${WEB_BASE}IssuedBooksServlet" novalidate="novalidate" onsubmit="return validateForm()">
				<input id="DateChooser" name="issuedate" type="date" min="2000-01-01"style="margin-left:-45px" />
				<input class="button" name="Button1" type="submit" value="Create Report" style="width:114px"/>
  
			  </form></td>

	</tr>
</table>
</div>
<jsp:include page="/jsp/footer.jsp" />
</body>
</html>